//引入vue
import Vue from 'vue'

//引入mint-ui
import MintUI from 'mint-ui'
Vue.use(MintUI)
import 'mint-ui/lib/style.css'
//引入mui
import './lib/mui/css/mui.css'
import './lib/mui/css/icons-extra.css'

//引入router
import VueRouter from 'vue-router'
Vue.use(VueRouter)

//引入axios
import Axios from 'axios'


// 导入格式化时间的插件
import moment from 'moment'
// 定义全局的过滤器
Vue.filter('dateFormat', function(dataStr, pattern = "YYYY-MM-DD HH:mm:ss") {
    return moment(dataStr).format(pattern)
})

//引入主组件
import App from './App.vue'

//按需引入
import { Header, Swipe, SwipeItem } from 'mint-ui'
Vue.component(Header.name, Header)
Vue.component(Swipe.name, Swipe);
Vue.component(SwipeItem.name, SwipeItem);

import router from './router.js'


import VueSource from 'vue-resource'
Vue.use(VueSource)
Vue.http.options.root = 'http://www.liulongbin.top:3005'
Vue.http.options.emulateJSON = true
var vm = new Vue({
    el: '#app',
    render: c => c(App),
    router
})